/*================================================================
*   Copyright (C) 2018 LiuYao. All rights reserved.
*   
*   Filename : gradient_descent_factory.h
*   Author : LiuYao
*   Date : 2018-01-03
*   Description : 
*
================================================================*/
#ifndef _GRADIENT_DESCENT_FACTORY_H
#define _GRADIENT_DESCENT_FACTORY_H

#include "factory.h"
#include "../graph/node.h"
#include "../graph/optimizers/gradient_descent_optimizer.h"

class GradientDescentFactory : public Factory {
    private:
        Node* node_;
        double alpha_;
        
        Node* hook() { return new GradientDescentOptimizer(node_, alpha_); }

    public:
        GradientDescentFactory(Node* node, double alpha) : node_(node), alpha_(alpha) {}
};

#endif
